<?php

	$a = glob('./tolower/*.*',GLOB_NOSORT);
	foreach($a as $var)
	{
		$dirName = dirname($var);
		$toLowerFileName = strtolower(basename($var));
		$fullName = $dirName.'/'.$toLowerFileName;
		rename($var, $fullName);
		echo $var . ' 转换成小写文件名 ' . $fullName .'<br />';
	}

?>